package service

import (
	"github.com/gin-gonic/gin"
	"github.com/go-kratos/kratos/v2/log"
	"transfer-service/internal/biz"
)

type WebsocketService struct {
	uc  *biz.WebsocketUseCase
	log *log.Helper
}

func NewWebsocketService(
	uc *biz.WebsocketUseCase,
	logger log.Logger,
) *WebsocketService {
	return &WebsocketService{
		uc:  uc,
		log: log.NewHelper(log.With(logger, "module", "service/Websocket")),
	}
}

func (s WebsocketService) HandleWebSocket(c *gin.Context) {
	s.uc.WsHandler(c)
}
